﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<ComeSeeThis_MVC2.Models.Motor>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
    Motor Details
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
     <% Html.RenderPartial("SubMenu"); %>
   <h2>
        Motor Details</h2>
    <fieldset>
        <legend>
            <%: Model.MotorName %></legend>
        <table width="300px">
            <tr>
                <th>
                    Company
                </th>
                <td>
                    <%: Model.Company.CompanyName %>
                </td>
            </tr>
            <tr>
                <th>
                    MotorName
                </th>
                <td>
                    <%: Model.MotorName %>
                </td>
            </tr>
            <tr>
                <th>
                    Part Number
                </th>
                <td>
                    <%: Model.PartNumber %>
                </td>
            </tr>
            <tr>
                <th>
                    Size
                </th>
                <td>
                    <%: Model.MotorSize.MotorSizeName %>
                </td>
            </tr>
            <tr>
                <th>
                    Turns
                </th>
                <td>
                    <%: String.Format("{0:F}", Model.Turns) %>
                </td>
            </tr>
            <tr>
                <th>
                    KiloVolt
                </th>
                <td>
                    <%: Model.KiloVolt %>
                </td>
            </tr>
            <tr>
                <th>
                    MagnetType
                </th>
                <td>
                    <%: Model.MagnetType %>
                </td>
            </tr>
            <tr>
                <th>
                    MagnetSize
                </th>
                <td>
                    <%: Model.MagnetSize %>
                </td>
            </tr>
            <tr>
                <th>
                    Watts
                </th>
                <td>
                    <%: String.Format("{0:F}", Model.Watts) %>
                </td>
            </tr>
            <tr>
                <th>
                    Sensored
                </th>
                <td>
                    <%: Model.Sensored %>
                </td>
            </tr>
            <tr>
                <th>
                    Approved
                </th>
                <td>
                    <%: Model.Approved %>
                </td>
            </tr>
            <tr>
                <th>
                    Notes
                </th>
                <td>
                    <%: Model.Notes %>
                </td>
            </tr>
        </table>
    </fieldset>
    <p>
        <%: Html.ActionLink("Back to List", "Index") %>
        <% if (User.IsInRole("SiteAdmin") || User.IsInRole("ContentAdmin"))
           { %>
        |
        <%:Html.ActionLink("Edit", "Edit", new {id=Model.MotorId, q = Request.Url.ToString() })%>
        <%  } %>
    </p>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="HeaderContent" runat="server">
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="BodyTagContent" runat="server">
</asp:Content>
